package com.zbkj.common.model.client.agent;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;
import java.util.Map;

/**
 * <p>
 * 客户端套餐配置表
 * </p>
 *
 * @author CRMEB Team
 * @since 2025-01-01
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName(value = "eb_client_package_config", autoResultMap = true)
@ApiModel(value = "PackageConfig对象", description = "客户端套餐配置表")
public class PackageConfig implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键ID")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "套餐等级")
    @TableField("package_level")
    private Integer packageLevel;

    @ApiModelProperty(value = "套餐名称")
    @TableField("name")
    private String name;

    @ApiModelProperty(value = "套餐描述")
    @TableField("desc")
    private String desc;

    @ApiModelProperty(value = "原价")
    @TableField("orginal_price")
    private BigDecimal orginalPrice;

    @ApiModelProperty(value = "优惠价格")
    @TableField("preferential_price")
    private BigDecimal preferentialPrice;

    @ApiModelProperty(value = "套餐赠送点数")
    @TableField("package_point")
    private Integer packagePoint;

    @ApiModelProperty(value = "标签，json格式")
    @TableField(value = "tag", typeHandler = JacksonTypeHandler.class)
    private List<String> tag;

    @ApiModelProperty(value = "套餐详情，json格式")
    @TableField(value = "config_list", typeHandler = JacksonTypeHandler.class)
    private Map<String, Map<String, Object>> configList;

    @ApiModelProperty(value = "是否删除，0-否，1-是")
    @TableLogic
    @TableField("is_del")
    private Integer isDel;

    @ApiModelProperty(value = "创建时间")
    @TableField("create_time")
    private Date createTime;

    @ApiModelProperty(value = "更新时间")
    @TableField("update_time")
    private Date updateTime;
} 